export function captureImage(videoEl) {
  // 创建一个画布元素，设置画布尺寸为视频流的尺寸
  const canvas = document.createElement('canvas')
    canvas.width = videoEl.value.videoWidth / 2
    canvas.height = videoEl.value.videoHeight / 2
  // 获取画布上下文对象
    const ctx = canvas.getContext('2d')
  // 将画布内容转为 Base64 数据
    ctx?.drawImage(videoEl.value, 0, 0, canvas.width, canvas.height)
    return canvas.toDataURL('image/png', 0.1)
  }